{% extends 'base.html' %}
{% load i18n %}
{% block boby %}
    <div class="offset-md-2 col-md-8 col-lg-8">
        <table class="table table-hover table-bordered">
            <thead class="thead-light">
                <tr>
                    <th colspan="2" class="text-center">{% translate '操作异常' %}</th>
                </tr>
            </thead>
            <tbody>
                <tr>
                    <td style="width: 100px;text-align: center">{% translate '异常编码' %}</td>
                    <td>{{ error_code }}</td>
                </tr>
                <tr>
                    <td style="width: 100px;text-align: center">{% translate '异常类型' %}</td>
                    <td>{{ error_type }}</td>
                </tr>
                <tr>
                    <td  style="vertical-align: middle; text-align: center">{% translate '提示' %}</td>
                    <td>
                        {% if error_tips %}
                            <ul class="list-group">
                            {% for tip in error_tips %}
                                <li class="list-group-item list-group-item-warning">{{ tip }}</li>
                            {% endfor %}
                            </ul>
                        {% endif %}
                    </td>
                </tr>
                {% if user.is_superuser %}
                    <tr>
                        <td  style="vertical-align: middle; text-align: center">Traceback</td>
                        <td class="bg-light">
                            {% if error_traceback %}
                               <pre><code>{{ error_traceback }}</code></pre>
                            {% endif %}
                        </td>
                    </tr>
                {% endif %}
            </tbody>
        </table>
    </div>
{% endblock %}
